
<!DOCTYPE html>
<html lang='zh-cn'>
<head>
  <meta charset='utf-8'>
  <meta http-equiv='X-UA-Compatible' content='IE=edge'>
  <meta name="viewport" content="width=device-width, initial-scale=1">
  <meta name="renderer" content="webkit">
  <title>用户登录 - 禅道</title>
  <script>window.config={"webRoot":"\/zentao\/","debug":false,"appName":"","cookieLife":30,"requestType":"PATH_INFO","requestFix":"-","moduleVar":"m","methodVar":"f","viewVar":"t","defaultView":"html","themeRoot":"\/zentao\/theme\/","currentModule":"user","currentMethod":"templates.login","clientLang":"zh-cn","requiredFields":"","router":"\/zentao\/index.php","save":"\u4fdd\u5b58","runMode":"","timeout":30000,"pingInterval":""};
  window.lang={"submitting":"\u7a0d\u5019...","save":"\u4fdd\u5b58","expand":"\u5c55\u5f00\u5168\u90e8","timeout":"\u8fde\u63a5\u8d85\u65f6\uff0c\u8bf7\u68c0\u67e5\u7f51\u7edc\u73af\u5883\uff0c\u6216\u91cd\u8bd5\uff01"};

  </script>
  <script>config.onlybody = "no";</script><link rel='stylesheet' href='/zentao/theme/default/zh-cn.default.css?v=12.5.3' type='text/css' media='screen' />
  <script src='/zentao/js/all.js?v=12.5.3'></script>
  <style>#featurebar ul.nav li .chosen-container a.chosen-single{background:#F8FAFE; border:none; -webkit-box-shadow:none;box-shadow:none; padding-top:5px;}
  .w-verifyPassword {width: 120px !important;}
  .w-enVerifyPassword {width: 150px !important;}
  body {background: #1183fb linear-gradient(-90deg, #0a48d1 0%, #1183fb 100%); background-color: #1183fb;}
  #login {max-width: 600px!important; margin: 0 auto; margin-top: 5%;}
  #loginPanel {background: #fff; overflow: hidden; box-shadow: 0 0 20px 0 rgba(0,0,0,.1); border-radius: 3px;}
  #loginPanel > header {padding: 20px; border-bottom: 1px #eee solid; position: relative;}
  #loginPanel > header > h2 {font-size: 16px; margin: 0; line-height: 32px; max-width: 83%;}
  #loginPanel > header > .actions {position: absolute; right: 20px; top: 20px;}
  #loginPanel > .table-row {margin: 20px 0;}
  #loginPanel .table-form > tbody > tr > th {width: 60px;}
  html[lang='en'] #loginPanel .table-form > tbody > tr > th {width: 80px;}
  #loginPanel form {margin-right: 40px;}
  #loginPanel > footer {background: #eee; padding: 20px; color: #838a9d}
  #loginPanel > footer a {display: inline-block; margin-left: 5px;}
  #info {margin-top: 10px; color: #fff;}
  #info .btn + .btn {margin-left: 5px;}
  #langs > .btn,
  #langs > .dropdown-menu {min-width: 0; width: 85px;}

  #logo-box img{margin-left:40px; width: 100px;}

  .showNotice{color:yellow;}
  .showNotice:hover{color:yellow;}
  </style><link rel='icon' href='/zentao/favicon.ico' type='image/x-icon' />
  <link rel='shortcut icon' href='/zentao/favicon.ico' type='image/x-icon' />
  <!--[if lt IE 10]>
  <script src='/zentao/js/jquery/placeholder/min.js?v=12.5.3'></script>
  <![endif]-->
</head>
<body>
<script src='/zentao/js/md5.js?v=12.5.3'></script>
<main id="main" class="fade no-padding">
  <div class="container" id="login">
    <div id="loginPanel">
      <header>
        <h2>易软天创项目管理系统</h2>
        <div class="actions dropdown dropdown-hover" id='langs'>
          <button type='button' class='btn' title='Change Language/更换语言/更換語言'>简体 <span class="caret"></span></button>
          <ul class="dropdown-menu pull-right">
            <li><a class="switch-lang" data-value="zh-cn">简体</a></li>
            <li><a class="switch-lang" data-value="zh-tw">繁體</a></li>
            <li><a class="switch-lang" data-value="en">English</a></li>
            <li><a class="switch-lang" data-value="de">Deutsch</a></li>
            <li><a class="switch-lang" data-value="fr">Français</a></li>
            <li><a class="switch-lang" data-value="vi">Tiếng Việt</a></li>
            <li><a class="switch-lang" data-value="ja">日本語</a></li>
          </ul>
        </div>
      </header>
      <div class="table-row">
        <div class="col-4 text-center" id='logo-box'>
          <img src="/zentao/theme/default/images/main/zt-logo.png" />
        </div>
        <div class="col-8">
          <form method='post' target='hiddenwin'>
            <table class='table table-form'>
              <tbody>
              <tr>
                <th>用户名</th>
                <td><input class='form-control' type='text' name='account' id='account' autofocus /></td>
              </tr>
              <tr>
                <th>密码</th>
                <td><input class='form-control' type='password' name='password' /></td>
              </tr>
              <tr>
                <th></th>
                <td id="keeplogin"><div class='checkbox-primary'><input type='checkbox' name='keepLogin[]' value='on'  checked ='checked' id='keepLoginon' /> <label for='keepLoginon'>保持登录</label></div></td>
              </tr>
              <tr>
                <td></td>
                <td class="form-actions">
                  <button type='submit' id='submit' class='btn btn-primary'  data-loading='稍候...'>登录</button><input type='hidden' name='referer' id='referer' value='/zentao/'  />
                  <input type='hidden' name='verifyRand' id='verifyRand' value='1216765091'  />
                  <a href='/zentao/user-reset.html' >忘记密码</a>
                </td>
              </tr>
              </tbody>
            </table>
          </form>
        </div>
      </div>
    </div>
    <div id="info" class="table-row">
      <div class="table-col text-middle text-center">
        <div id="poweredby">
          <div><a class='showNotice' href='javascript:showNotice()',>警告：检测到一键安装包密码口令弱</a></div>
          <iframe id='updater' class='hidden' frameborder='0' width='100%' height='45' scrolling='no' allowtransparency='true' src="/zentao/misc-checkUpdate-.html"></iframe>
        </div>
      </div>
    </div>
  </div>
</main>
<script>process4Safe = "\u68c0\u6d4b\u5230\u60a8\u53ef\u80fd\u5728\u4f7f\u7528\u4e00\u952e\u5b89\u88c5\u5305\u73af\u5883\uff0c\u8be5\u73af\u5883\u4e2d\u5176\u4ed6\u7ad9\u70b9\u8fd8\u5728\u7528\u7b80\u5355\u5bc6\u7801\uff0c\u5b89\u5168\u8d77\u89c1\uff0c\u5982\u679c\u4e0d\u4f7f\u7528\u5176\u4ed6\u7ad9\u70b9\uff0c\u8bf7\u53ca\u65f6\u5904\u7406\u3002\u8bf7\u767b\u5f55\u6570\u636e\u5e93\uff0c\u4fee\u6539 zentaopro zentaoep \u6570\u636e\u5e93\u7684zt_user\u8868\u7684password\u5b57\u6bb5\u3002\u8be6\u60c5\u67e5\u770b\uff1a<a href='https:\/\/www.zentao.net\/book\/zentaopmshelp\/467.html' target='_blank'>https:\/\/www.zentao.net\/book\/zentaopmshelp\/467.html<\/a>";</script>
<iframe frameborder='0' name='hiddenwin' id='hiddenwin' scrolling='no' class='debugwin hidden'></iframe>
<script>
  /**
   * Switch account
   *
   * @param  string $account
   * @param  string $method
   * @access public
   * @return void
   */
  $(document).ready(function()
  {
    var verifyEncrypted = false;
    $('#verifyPassword').change(function(){verifyEncrypted = false})
    $('#verifyPassword').closest('form').find('#submit').click(function()
    {
      var password = $('input#verifyPassword').val().trim();
      var rand = $('input#verifyRand').val();
      if(!verifyEncrypted && password) $('input#verifyPassword').val(md5(md5(password) + rand));
      verifyEncrypted = true;
    });
  });

  function switchAccount(account, method)
  {
    if(method == 'dynamic')
    {
      link = createLink('user', method, 'period=' + period + '&account=' + account);
    }
    else if(method == 'todo')
    {
      link = createLink('user', method, 'account=' + account + '&type=' + type);
    }
    else
    {
      link = createLink('user', method, 'account=' + account);
    }
    location.href=link;
  }

  var mailsuffix = '';
  var account    = [];
  function setDefaultEmail(num)
  {
    var mailValue = $('.email_' + num).val();
    if(mailValue.indexOf('@') <= 0) return;
    if(mailValue.indexOf('@') > 0) mailValue = mailValue.substr(mailValue.indexOf('@'));
    mailsuffix = mailValue;
  }

  function changeEmail(num)
  {
    var mailValue = $('.email_' + num).val();
    if(mailsuffix != '' && (mailValue == '' || mailValue == account[num] + mailsuffix)) $('.email_' + num).val($('.account_' + num).val() + mailsuffix);
    account[num] = $('.account_' + num).val();
  }

  function checkPassword(password)
  {
    $('#passwordStrength').html(password == '' ? '' : passwordStrengthList[computePasswordStrength(password)]);
    $('#passwordStrength').css('display', password == '' ? 'none' : 'table-cell');
  }
  // Prevent login page show in a iframe modal
  if(window.self !== window.top) window.top.location.href = window.location.href;

  $(document).ready(function()
  {
    /* Fix bug for misc-ping */
    $('#hiddenwin').removeAttr('id');

    var $login = $('#login');
    var adjustPanelPos = function()
    {
      var bestTop = Math.max(0, Math.floor($(window).height() - $login.outerHeight())/2);
      $login.css('margin-top', bestTop);
    };
    adjustPanelPos();
    $(window).on('resize', adjustPanelPos);

    $('#account').focus();

    $("#langs li > a").click(function()
    {
      selectLang($(this).data('value'));
    });

    $('#loginPanel #submit').click(function()
    {
      var account          = $('#account').val().trim();
      var password         = $('input:password').val().trim();
      var passwordStrength = computePasswordStrength(password);

      var hasMD5    = typeof(md5) == 'function';
      var rand      = $('input#verifyRand').val();
      var referer   = $('#referer').val();
      var link      = createLink('user', 'templates.login');
      var keepLogin = $('#keepLoginon').attr('checked') == 'checked' ? 1 : 0;

      $.ajax
      ({
        url: link,
        dataType: 'json',
        method: 'POST',
        data:
                {
                  "account": account,
                  "password": hasMD5 ? md5(md5(password) + rand) : password,
                  'passwordStrength' : passwordStrength,
                  'referer' : referer,
                  'verifyRand' : rand,
                  'keepLogin' : keepLogin,
                },
        success:function(data)
        {
          if(data.result == 'fail')
          {
            alert(data.message);
            return false;
          }
          else
          {
            location.href = data.locate;
          }
        }
      })

      return false;
    });
  });

  /**
   * Show notice for one click package use weak password.
   *
   * @access public
   * @return void
   */
  function showNotice()
  {
    if(typeof(process4Safe) == 'string') bootbox.alert(process4Safe)
  }
</script>
</body>
</html>
